﻿<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="~/Popup.Master" CodeBehind="DODraft.aspx.cs"
    Inherits="VSM.Parts.DODraft" EnableEventValidation="false" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div>
        <asp:UpdatePanel ID="updatePanel" runat="server" UpdateMode="Conditional">
            <ContentTemplate>
                <asp:HiddenField ID="hdnDocType" runat="server" />
                <div style="height: 525px; overflow: scroll">
                    <table id="Table1" width="100%" style="font-weight: bold">
                        <tr>
                            <td class="FormLineItemAlt" style="width: 7%;">
                                &nbsp;Customer:
                            </td>
                            <td class="FormLineItemAlt" style="white-space: nowrap; width: 18%;" valign="middle">
                                <asp:TextBox ID="txtCardCode" runat="server" Width="100px"></asp:TextBox>
                            </td>
                            <td class="FormLineItemAlt" style="width: 7%;">
                                Debit Note:
                            </td>
                            <td class="FormLineItemAlt" style="white-space: nowrap; width: 18%;" valign="middle">
                                <asp:TextBox ID="txtDebitNote" runat="server" Width="100px"></asp:TextBox>
                                <asp:Button ID="btnFilterByName" runat="server" OnClick="btnFiletrByName_Click" Style="background-image: url('/Images/bgButton.png');
                                    background-repeat: no-repeat;" Text="Search" Width="80px" />
                            </td>
                        </tr>
                        <tr>
                            <td class="FormLineItem" valign="middle">
                                From Start Date:
                            </td>
                            <td class="FormLineItem" valign="middle">
                                <asp:TextBox ID="txtFromStartDate" Width="100px" runat="server"></asp:TextBox>
                                <cc1:CalendarExtender ID="txtFromStartDate_CalendarExtender" runat="server" Format="dd/MM/yyyy"
                                    PopupButtonID="imgFromDocDate" TargetControlID="txtFromStartDate">
                                </cc1:CalendarExtender>
                                <asp:ImageButton ID="imgFromDocDate" runat="Server" AlternateText="Click to show calendar"
                                    ImageUrl="~/Images/Calendar_scheduleHS.png" />
                            </td>
                            <td class="FormLineItem" valign="middle">
                                To Start Date:
                            </td>
                            <td class="FormLineItem" valign="middle">
                                <asp:TextBox ID="txtToStartDate" runat="server" Width="100px"></asp:TextBox>
                                <cc1:CalendarExtender ID="txtToStartDate_CalendarExtender" runat="server" Format="dd/MM/yyyy"
                                    PopupButtonID="imgToDocDate" TargetControlID="txtToStartDate">
                                </cc1:CalendarExtender>
                                <asp:ImageButton ID="imgToDocDate" runat="Server" AlternateText="Click to show calendar"
                                    ImageUrl="~/Images/Calendar_scheduleHS.png" />
                            </td>
                        </tr>
                    </table>
                    <table style="width: 100%; border: 1px;" cellpadding="3" cellspacing="0">
                        <tr>
                            <td colspan="2" style="text-align: center;">
                                <asp:GridView ID="grvFCT1List" runat="server" CssClass="GridInner" Width="100%" BorderColor="White"
                                    BackColor="White" AllowSorting="True" AutoGenerateColumns="False" CellPadding="2"
                                    HeaderStyle-Height="27px" OnSorting="grdBP_Sorting" OnSelectedIndexChanged="grdBP_SelectedIndexChanged"
                                    OnRowDataBound="grdBP_RowDataBound">
                                    <RowStyle BackColor="#D9E0ED" ForeColor="Black" BorderColor="White" BorderWidth="2px"
                                        Height="25px" />
                                    <AlternatingRowStyle BackColor="#EEF1F7" BorderColor="White" BorderWidth="2px" Height="25px" />
                                    <Columns>
                                        <asp:TemplateField HeaderText="ID">
                                            <ItemStyle HorizontalAlign="Center" />
                                            <HeaderStyle VerticalAlign="Middle" />
                                            <ItemTemplate>
                                                <asp:Label ID="lblDocEntry" runat="server" Text='<%# Bind("DocEntry") %>' BorderStyle="none">
                                                </asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:TemplateField HeaderText="Customer Code">
                                            <ItemStyle HorizontalAlign="Center" />
                                            <HeaderStyle VerticalAlign="Middle" />
                                            <ItemTemplate>
                                                <asp:Label ID="lblCardCode" runat="server" Text='<%# Bind("CardCode")%>' BorderStyle="none">
                                                </asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:TemplateField HeaderText="Customer Name">
                                            <ItemStyle HorizontalAlign="Center" />
                                            <HeaderStyle VerticalAlign="Middle" />
                                            <ItemTemplate>
                                                <asp:Label ID="lblCardName" runat="server" Text='<%# Bind("CardName")%>' BorderStyle="none">
                                                </asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:TemplateField HeaderText="SO Number">
                                            <ItemStyle HorizontalAlign="Center" />
                                            <HeaderStyle VerticalAlign="Middle" />
                                            <ItemTemplate>
                                                <asp:Label ID="lblTransferNBR" runat="server" Text='<%# Bind("U_SONBR") %>'
                                                    BorderStyle="none">
                                                </asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:TemplateField HeaderText="Debit Note ">
                                            <ItemStyle HorizontalAlign="Center" />
                                            <HeaderStyle VerticalAlign="Middle" />
                                            <ItemTemplate>
                                                <asp:Label ID="lblDebitNote" runat="server" Text='<%# Bind("U_DebitNote") %>' BorderStyle="none">
                                                </asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:TemplateField HeaderText="Posting Date">
                                            <ItemStyle HorizontalAlign="Center" />
                                            <HeaderStyle VerticalAlign="Middle" />
                                            <ItemTemplate>
                                                <asp:Label ID="lblEndDate" runat="server" Text='<%# Bind("DocDate", "{0:dd/MM/yyyy}")%>'
                                                    BorderStyle="none">
                                                </asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:TemplateField HeaderText="Remarks">
                                            <ItemStyle HorizontalAlign="Center" />
                                            <HeaderStyle VerticalAlign="Middle" />
                                            <ItemTemplate>
                                                <asp:Label ID="lblRemarks" runat="server" Text='<%# Bind("Comments", "{0:dd/MM/yyyy}")%>'
                                                    BorderStyle="none">
                                                </asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                           <asp:TemplateField HeaderText="DocType" Visible="false">
                                            <ItemStyle HorizontalAlign="Center" />
                                            <HeaderStyle VerticalAlign="Middle" />
                                            <ItemTemplate>
                                                <asp:Label ID="lblDocType" runat="server" BorderStyle="none">
                                                </asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                    </Columns>
                                    <PagerStyle BackColor="#C6C3C6" ForeColor="Black" HorizontalAlign="Right" />
                                    <SelectedRowStyle Font-Bold="true" ForeColor="Red" />
                                    <HeaderStyle BackColor="#6095C9" Font-Bold="true" ForeColor="#ffffff" Font-Overline="False"
                                        Height="27px" VerticalAlign="Bottom" />
                                    <EmptyDataTemplate>
                                        No Data Found.
                                    </EmptyDataTemplate>
                                </asp:GridView>
                            </td>
                        </tr>
                    </table>
                </div>
                <div>
                    <table id="tblFooter" width="100%" style="font-weight: bold">
                        <tr>
                            <td>
                                <asp:Timer ID="Timer1" runat="server" Interval="1" OnTick="Timer1_Tick" />
                                <asp:Button ID="btnAccept" runat="server" Text="OK" OnClick="btnAccept_Click" Style="background-image: url('/Images/bgButton.png');
                                    background-repeat: no-repeat;" Width="80px" />
                            </td>
                        </tr>
                    </table>
                </div>
            </ContentTemplate>
        </asp:UpdatePanel>
    </div>
</asp:Content>
